package homework8;

import java.io.BufferedReader;
import java.io.FileInputStream;
import java.io.FileNotFoundException;
import java.io.FileOutputStream;
import java.io.FileReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.OutputStream;
import java.util.ArrayList;
import java.util.Random;

public class CallName1 {
	public static void main(String[] args) throws NumberFormatException, IOException {
		Random r=new Random();
		int n=r.nextInt(100);
		ArrayList<Student> list=new ArrayList<Student>();
		BufferedReader br=new BufferedReader(new FileReader("names.txt"));
		String line;
		
		while((line=br.readLine())!=null){
			String[] arr = line.split("-");
			list.add(new Student(arr[0],arr[1],Integer.parseInt(arr[2].toString())));
		}
		System.out.println(list.get(n).getName());
		
		
		
		
		
		
		
		
		
		
	}
}
